home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Game-Power
/
Amiga Game-Power.iso
/
anwendungen
/
d mouse
/
check
/
check.doc
< prev
next >
Wrap
Text File
|
1994-05-20
|
5KB
|
126 lines
Check V1.03 Copyright 1987, 1988 Keith Elbertson. All Rights Reserved.
The Author, Keith Elbertson, grants permission for distribution of the
executable version of CHECK V1.03. The program my be freely distributed
non-commercially, so long as this file accompanies the executable file.
No fees may be charged for this program.
Permission is not given for distribution for Commercial purposes, without
written consent by the Author. Source code is not available, since it will
be part of a larger commercial product released in the near future.
This is the fourth revision of CHECK. There are no bugs in the program
that I am aware of. If you find any though, please let me know about them
as soon as possible. I've spent many hours making sure that I squashed them
all but sometimes real tiny ones manage to get away. Also, if you have any
recommendations about other enhancements or changes you would like to see,
drop me a line.
I can be reached on the BBS-ARIA in Pembroke Pines, Fl. 305-435-9837 or
by mail:
Information Cartel, Inc.
Attn:Keith Elbertson
P.O. BOX 840535
Pembroke Pines, Fl. 33084
USAGE:
CHECK [flags] Filename
The flags are optional. With no flags set, Check will run a test of
the source files control structures, and report what it found. This
information can be used to locate problems in the programs flow control
structures before attempting a compile.
If CHECK finds something out of balance, it will put a pointer next to
that structures report line, to draw attention to the possible problem.
If nothing has the arrow next to it, you can be fairly sure that
everything is OK with the programs basic structure. No attempt has been
made in this version to syntactically check the file.
The best feature of CHECK is that you can view any particular control
structure(s) by setting that structures flag. Multiple flags can be set
at a time. Any structure selected will be displayed in inverse video as
the file is viewed, making it easier to spot the problem. It's much faster
than looking at plain source code, or trying to figure out what those
sometimes cryptic compiler error messages mean.
Check will also convert CR/LF to LF only, which is the standard format
for Amiga files. This is handy for converting files from other machines.
Flags are set by typing a "-" immediately followed by a number or
letter. The case of the letter is insignificant.
Example: CHECK -c -d filename
This would cause comments, and double quotes to be displayed in inverse
video as it was typed to the screen.
Certain flags will not work in conjuction with others. In these cases,
the first flag set takes priority over the later incompatible one. These
incompatibilities are pointed out below.
FLAGS:
-A View text enclosed in brackets.
-B View nesting of braces. This depth is displayed by a 3 digit
number in inverse video to the left of the screen.
-C View text enclosed in comments. This option cannot be used in
conjunction with the -X option.
-D View strings enclosed in double quotes.
-L Print line numbers in inverse video along with text.
-N Allow nesting of comments. Works with both viewing and stripping.
-O Output to a file instead of the screen. Text of the filename should
follow the -O without any spaces in between the O and the name.
Example:
CHECK -oram:temp check.c
will send the results of the check to ram:temp.
-P View text enclosed in parenthesis.
-R Check does not normally display results when viewing a file.
Setting this flag will display the results when done.
-S View strings enclose in single quotes.
-X Strips commented text from the output. This option cannot be used
in conjunction with the -C option.
-0 Zero/Reset video display to normal. If you used Ctrl-C to stop CHECK
prematurely, and were left in inverse video mode, this will fix the
display. CHECK resets the display when it exits normally.
HOW TO:
1. First run check on the program to see if all control structures are in
balance. If everything is in balance, try to compile the code.
2. If something is out-of-balance. Run the check again with the flag(s)
set that will allow you to view the source code for that type of error.
3. If you can't find an error in the source file, run a check on any
header files that you have created. Occasionally this is where the
real error is but shows up as the source file having the error.
P.S.
This won't find all of your bugs, but if your code passes a CHECK, you can
be pretty sure the code is structured properly.
I have gotten plenty of use from CHECK since writting it. I know the time
it took authoring it were well spent since it has saved me countless hours
in debugging. I hope you will find CHECK as useful as I have.
Happy Hacking,
Keith Elbertson